package net.aiion.weave;

import net.aiion.weave.spi.painters.PaintBrush;
import net.aiion.weave.spi.painters.PaintContext;
import net.aiion.weave.spi.painters.Painter;
import net.aiion.weave.spi.painters.annotations.Paints;

public class PaintingClass implements Painter
{
    @Override
    public PaintBrush paintComponent(PaintContext aPainterContext) {
        final Object o = aPainterContext.getComponent();
        if (PaintingClass.class.isInstance(o)) {
            return paintComponent(aPainterContext);
        }

        return aPainterContext.forwardPaint();
    }

    @Paints(PaintingClass.class)
    public PaintBrush paint(PaintContext aPainterContext) {
        return null;
    }
}
